this._userVerifier.connect('verification-failed', Lang.bind(this, this._onVerificationFailed));
this._userVerifier.connect('reset', Lang.bind(this, this._onReset));
- this._userVerifier.connect('show-fingerprint-prompt', Lang.bind(this, this._showFingerprintPrompt));
- this._userVerifier.connect('hide-fingerprint-prompt', Lang.bind(this, this._hideFingerprintPrompt));
+ this._userVerifier.connect('show-login-hint', Lang.bind(this, this._showLoginHint));
+ this._userVerifier.connect('hide-login-hint', Lang.bind(this, this._hideLoginHint));
this._settings = new Gio.Settings({ schema: GdmUtil.LOGIN_SCREEN_SCHEMA });
x_fill: true,
y_fill: false,
x_align: St.Align.START });
- // Translators: this message is shown below the password entry field
- // to indicate the user can swipe their finger instead
- this._promptFingerprintMessage = new St.Label({ text: _("(or swipe finger)"),
- style_class: 'login-dialog-prompt-fingerprint-message' });
- this._promptFingerprintMessage.hide();
- this._promptBox.add(this._promptFingerprintMessage);
+ this._promptLoginHint = new St.Label({ style_class: 'login-dialog-prompt-login-hint-message' });
+ this._promptLoginHint.hide();
+ this._promptBox.add(this._promptLoginHint);
this._sessionList = new SessionList();
this._sessionList.connect('session-activated',
function() {
this._sessionList.close();
- this._promptFingerprintMessage.hide();
+ this._promptLoginHint.hide();
this._userList.actor.show();
this._userList.actor.opacity = 255;
return this._userList.showItems();
this._sessionList.setActiveSession(sessionId);
},
- _showFingerprintPrompt: function() {
- GdmUtil.fadeInActor(this._promptFingerprintMessage);
+ _showLoginHint: function(verifier, message) {
+ this._promptLoginHint.set_text(message)
+ GdmUtil.fadeInActor(this._promptLoginHint);
},
- _hideFingerprintPrompt: function() {
- GdmUtil.fadeOutActor(this._promptFingerprintMessage);
+ _hideLoginHint: function() {
+ GdmUtil.fadeOutActor(this._promptLoginHint);
+ this._promptLoginHint.set_text('');
},
cancel: function() {
function() {
// Show it with 0 opacity so we preallocate space for it
// in the event we need to fade in the message
- this._promptFingerprintMessage.opacity = 0;
- this._promptFingerprintMessage.show();
+ this._promptLoginHint.opacity = 0;
+ this._promptLoginHint.show();
},
function() {
},
function() {
- this._promptFingerprintMessage.hide();
+ this._promptLoginHint.hide();
this._promptEntry.reactive = true;
this._promptEntry.set_text('');
}];
// as a cue to display our own message.
if (serviceName == FINGERPRINT_SERVICE_NAME &&
this._haveFingerprintReader) {
- this.emit('show-fingerprint-prompt');
+
+ // Translators: this message is shown below the password entry field
+ // to indicate the user can swipe their finger instead
+ this.emit('show-login-hint', _("(or swipe finger)"));
} else if (serviceName == PASSWORD_SERVICE_NAME) {
Main.notifyError(info);
}
if (serviceName == PASSWORD_SERVICE_NAME) {
this.emit('verification-failed');
} else if (serviceName == FINGERPRINT_SERVICE_NAME) {
- this.emit('hide-fingerprint-prompt');
+ this.emit('hide-login-hint');
}
},
});
this._userVerifier.connect('verification-complete', Lang.bind(this, this._onVerificationComplete));
this._userVerifier.connect('verification-failed', Lang.bind(this, this._onVerificationFailed));
- this._userVerifier.connect('show-fingerprint-prompt', Lang.bind(this, this._showFingerprintPrompt));
- this._userVerifier.connect('hide-fingerprint-prompt', Lang.bind(this, this._hideFingerprintPrompt));
+ this._userVerifier.connect('show-login-hint', Lang.bind(this, this._showLoginHint));
+ this._userVerifier.connect('hide-login-hint', Lang.bind(this, this._hideLoginHint));
this._userWidget = new UserWidget(this._user);
this.contentLayout.add_actor(this._userWidget.actor);
this.contentLayout.add_actor(this._promptLayout);
- // Translators: this message is shown below the password entry field
- // to indicate the user can swipe their finger instead
- this._promptFingerprintMessage = new St.Label({ text: _("(or swipe finger)"),
- style_class: 'login-dialog-prompt-fingerprint-message' });
- this._promptFingerprintMessage.hide();
- this.contentLayout.add_actor(this._promptFingerprintMessage);
+ this._promptLoginHint = new St.Label({ style_class: 'login-dialog-prompt-login-hint' });
+ this._promptLoginHint.hide();
+ this.contentLayout.add_actor(this._promptLoginHint);
let cancelButton = { label: _("Cancel"),
action: Lang.bind(this, this._escape),
this._updateOkButton(true);
},
- _showFingerprintPrompt: function() {
- GdmUtil.fadeInActor(this._promptFingerprintMessage);
+ _showLoginHint: function(verifier, message) {
+ this._promptLoginHint.set_text(message)
+ GdmUtil.fadeInActor(this._promptLoginHint);
},
- _hideFingerprintPrompt: function() {
- GdmUtil.fadeOutActor(this._promptFingerprintMessage);
+ _hideLoginHint: function() {
+ GdmUtil.fadeOutActor(this._promptLoginHint);
},
_doUnlock: function() {